#pragma once
#include <Windows.h>
#include <gl/glut.h>

#include "../common/Ptr.hpp"
#include "../common/ShowListManager.h"
#include "Terrain.h"


class TerrainModel
{
private:
  GLuint _showListName;
  GLuint textID;
  UINT _width, _height, _altitude;

  void _build_show_list (Ptr< Terrain > pData,
                         Ptr< ShowListManager > pShowListMng);

public:
  TerrainModel(Ptr< Terrain > pData, Ptr< ShowListManager > pShowListMng);
  void draw () const;
  UINT width () const { return _width; }
  UINT height () const { return _height; }
  UINT altitude () const { return _altitude; }
};
